package com.export.entity;

import com.alibaba.excel.annotation.ExcelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 接口报表返回数据
 *
 * @author yuanqinglong
 * @date 2021/07/26
 * @since 2021/7/21 16:54
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class ProductReport extends CalculateRate {

    /**
     * 开始时间
     */
    @ExcelProperty(value = "开始时间")
    private String startDate;
    /**
     * 结束时间
     */
    @ExcelProperty(value = "结束时间")
    private String endDate;
    /**
     * 接口uid
     */
    @ExcelProperty(value = "接口uid")
    private String prodUid;
    /**
     * 接口名称
     */
    @ExcelProperty(value = "接口名称")
    private String prodName;
    /**
     * 接口分类
     */
    @ExcelProperty(value = "接口分类")
    private String prtyFname;

    /**
     * 处理属性值
     *
     * @param reportParam 报告参数
     */
    public void processingAttributeValue(ReportParam reportParam){
        startDate = reportParam.getOriginalStartDate();
        endDate = reportParam.getOriginalEndDate();
        super.calculateRate();
    }
}
